﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Linq;
using System.Text.RegularExpressions;
using System.Web;
using System.Web.Mvc;
using System.Web.UI.WebControls;
using GWEB.WebBase.Data;
using GWEB.WebBase.Entity;
using GWEB.WebBase.Utility;
using GWEB.WebFrame.Public;

namespace GWEB.WebFrame.Evaluate
{
    public class EvaluatesController : PageInfoBase
    {
        [ActionFilter(IsLogin = true)]
        public ActionResult Index(String id, String keyCode)
        {
            return Load("Evaluates", "Evaluate/Evaluates", id, keyCode);
        }
        protected override void FieldAddInit(DataRow data) { data["state"] = 1; }
        protected override SqlState SqlExecute(BaseData bd, String id, Dictionary<String, Object> data)
        {
            if (id.Equals("-1"))
            {
                DataRow drUser = BasePage.GetUser(Session);
                data["LeagueId"] = drUser["LeagueId"];
            }
            return SqlState.None;
        }
    }
}